<?php //debug($planos);?>
<?php echo $this->Form->create('planos', array('action' => 'planos')); ?>
<div class="widget">
    <div class="whead"><h6>LISTADO DE PLANOS</h6><div class="clear"></div></div>
    <div class="shownpars">
        <table cellpadding="0" cellspacing="0" border="0" class="dTable">
            <thead>
                <tr>
                    <th>Nro</th>
                    <th>Numero de Orden</th>
                    <th>Transmittal</th>
                    <th>Proyecto</th>                     
                    <th>Caja</th>
                    <th>Nueva Caja</th>                                                                           
                    <th>Acciones</th> 
                </tr>
            </thead>
            <tbody>
                <?php $i = 1; ?>
                <?php foreach ($planos as $plan): ?>                
                <tr class="gradeX">
                <td><?php echo $i; $i++; ?></td>
                <td>
                <?php 
                if($plan['Plano']['ordene_id']==0)
                {
                    echo $plan['Plano']['po'];
                }
                else
                {
                    echo $plan['Ordene']['nombre'];
                }                                
                ?>                              
                </td>
                <td><?php echo $plan['Plano']['transmital'];?></td>                                                                                                 
                <td><?php echo $plan['Plano']['proyecto'];?></td>                                                                                                 
                <td><?php echo $plan['Plano']['lugar'];?></td>
                <td><?php echo $plan['Plano']['nuevolugar'];?></td>
                <td>
                    <?php echo $this->Html->link('EDITAR',array('action'=>'editar',$plan['Plano']['id']));?> -                                  
                    <?php echo $this->Html->link('DOCUMENTOS ID',array('controller'=>'PlanosTags', 'action'=>'listado',$plan['Plano']['id']));?> -                                      
                    <?php
                            echo $this->Html->Link(
                                    'Eliminar', array('action' => 'eliminar', $plan['Plano']['id']), array('confirm' => "Seguro de eliminar ?"));
                            ?>
                <?php //echo $this->Html->link('ELIMINAR',array('action'=>'eliminar',$plan['Plano']['id']),null,('Desea aliminar este Plano.....!!!!!')); ?></td>
                <?php //echo $this->Html->link('ISERTAR PLANO',array('action'=>'editar',$plan['Plano']['id']));?>
                </tr>
                <?php endforeach; ?>                
            </tbody>
        </table>
    </div> 
</div> 
<?php echo $this->Html->link('INSERTAR NUEVO PLANO',array('action'=>'insertar'),array('class'=>'buttonS bGreen'));?>
